#ifndef CALIBRATION_H
#define CALIBRATION_H

#include <QWidget>
#include <QUdpSocket>
#include "dataFormate.h"
#include <QTimer>
namespace Ui {
class Calibration;
}

class Calibration : public QWidget
{
    Q_OBJECT

public:
    explicit Calibration(QWidget *parent = nullptr);
    ~Calibration();

protected:
    virtual void changeEvent(QEvent* event);

signals:
    void sendRealParam(ST_RealParam);

protected:
     void paintEvent(QPaintEvent *event);
private slots:
    void receiveData();

    void on_calibration_Btn_clicked();

    void on_cancel_Btn_clicked();

    void on_confirm_Btn_clicked();

    //动画效果
    void slotAnimationControl();
private:

    //角度显示
    void angleDisplay(int x,int y);

private:
    Ui::Calibration *ui;
    QUdpSocket *m_udpsocket;
    int xOffset,yOffset,currentX,currentY;
    QTimer *animalTimer;
};

#endif // CALIBRATION_H
